<?php

$user = trim($_POST['userQQ']);
$name = trim($_POST['userName']);
include_once 'connect.php';

$sql = "update text set userQQ = '$user',userName = '$name' ";
$result = mysqli_query($connect, $sql);
if ($result) {
    echo "<script>alert('更新成功');location.href = 'user.php';</script>";
} else {
    echo "<script>alert('更新失败');history.back();</script>";
}
